﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;


class spiral
{
    static void Main()
    {
        Console.WriteLine("Enter N: ");
        int n = Convert.ToInt32(Console.ReadLine());
        Console.WriteLine();
        for (int i = 1; i <= n; i++)
        {
            for (int j = i; j <= i + (n - 1); j++)
            {
                Console.Write(" {0} ", j);
            }
            Console.WriteLine();
        }
        Console.WriteLine();
    }
}

